<?php
	/* 
	 * Proof of Concept Code Only! 
	 */
	if (strlen($_GET["hostid"]) == 0 || strlen($_GET["email"]) == 0) {
		echo "Error the request did not contain a hostid or email!";
	} else {
		$email = "Email: ".$_GET["email"];
		$hostId = "HostId: ".$_GET["hostid"];
		$file = "/tmp/hosts.txt";
		$fp = fopen($file, 'a');
		fwrite($fp, $email);
		fwrite($fp, "\n");
		fwrite($fp, $hostId);
		fwrite($fp, "\n\n");
		fclose($fp);
		echo "Success!";
	}
?>